package com.huluobo.a2201mvvm_imdemo.shop;

import androidx.lifecycle.MutableLiveData;

import com.huluobo.a2201mvvm_imdemo.mvvm.BaseViewModel;

/**
 * Created by LC on 2024/4/8.
 */
public class DetailViewModel extends BaseViewModel<DetailRepo> {
    MutableLiveData<GoodsDetailBeanResult> success = new MutableLiveData<>();

    MutableLiveData<String> failed = new MutableLiveData<>();

    public void getGoodsDetail(int goodsId) {
        repo.getGoodsDetail(goodsId, success, failed);
    }

    @Override
    protected DetailRepo createRepo() {
        return new DetailRepo();
    }
}
